Image data combining apparatus and method

ABSTRACT

An image data combining apparatus combines m lines of image data that have been output from a reading unit. The reading unit outputs m lines of image data based upon the pixel data that has been output upon being divided into the plurality of lines, and stored then in a memory. An upper address for accessing the memory is decided based upon first data indicating position, along the sub-scan direction, of an image that has been read by the reading unit, and a lower address for accessing the memory is decided based upon second data indicating position of the image along the main-scan direction. For the lower address utilizes values in which the sequence of a plurality of bits constituting the first data is interchanged, so that p items of pixel data at a time are extracted successively from each of the m lines of image data.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to an image data combining apparatus forcombining a plurality of lines of image data that have been output froma reading unit.

2. Description of the Related Art

A known method of obtaining image data by reading a document image orthe like is to read the image using a line sensor, store the read datain a line memory and subject the data to image processing (e.g., see thespecification of U.S. Pat. No. 6,765,703).

Another method known in the art involves dividing sensor pixels, whichhave been formed on one line, into even- and odd-numbered rows,outputting data, rearranging within the sensor and executing processingof the data as one line of data (e.g., see the specification of U.S.Pat. No. 6,717,617). Thus dividing one line of data from a line sensorand reading out data as a plurality of lines is referred to as “dividedreadout”. The reason for performing divided readout is to reduce thenumber of transferred pixels of the line sensor when image data per lineis read out, thereby raising readout speed.

In another known arrangement, image data read by scanning a line sensorin the direction in which sensor elements are arrayed (the main-scandirection) is stored in a memory (a band memory) in plural-line units(band units), and the data is then subjected to image processing.Corresponding two-dimensional image portions are developed in the bandmemory.

Further, the specification of Japanese Patent Laid-Open No. 2006-139606describes a method of scanning such a band memory in a direction(sub-scan direction) perpendicular to the line, reading out pixel dataand executing image processing.

However, in order to deal with the recent demand for higher definitionof read images, the number of sensor elements required on one line isincreasing and so is the required capacity of the line memory. With theconventional method of using a line memory, apparatus cost rises and thestructure of the apparatus is made more complicated by increasing thesemiconductor chips used. Further, in the case of the arrangement inwhich pixels are arrayed in a row within the sensor, as in U.S. Pat. No.6,717,617, the scale of the sensor itself increases and it is difficultto reduce the size of the apparatus.

SUMMARY OF THE INVENTION

An object of the present invention is to combine m lines of image data,which have been output from a reading unit, by a simple arrangement.

Another object of the present invention is to provide An image datacombining apparatus for combining m lines (where m is an integer equalto or greater than 2) of image data that have been output from a readingunit, wherein the reading unit has a plurality of line sensors arrangedin parallel, each of the plurality of line sensors outputs pixel dataupon dividing the data into a plurality of lines, the reading unitoutputs m lines of image data based upon the pixel data that has beenoutput upon being divided into the plurality of lines, and the output mlines of image data are stored in a memory, the apparatus comprises:

an access unit configured to access the memory; and

a determination unit configured to determine an upper address used foraccessing the memory by the access unit, based upon first data thatindicates position, along the sub-scan direction, of an image that hasbeen read by the reading unit, and determine a lower address used foraccessing the memory by the access unit, based upon second data thatindicates position of the image along the main-scan direction;

wherein the lower address includes values in which the sequence of aplurality of bits constituting the second data is interchanged in such amanner that p items (where p is an integer equal to or greater than 1)of pixel data at a time are extracted successively from each of the mlines of image data.

Further features of the present invention will become apparent from thefollowing description of exemplary embodiments with reference to theattached drawings.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram illustrating an example of the overallconfiguration of an image processing apparatus according to a firstembodiment of the present invention;

FIG. 2 is a block diagram illustrating an example of the circuitconfiguration of an image processing controller in an image processingunit according to the first embodiment;

FIGS. 3A to 3E are diagrams illustrating an example of operation of bandprocessing according to the embodiment;

FIG. 4A is a diagram illustrating an example of the structure of a CCDsensor according to the first embodiment;

FIG. 4B is a diagram illustrating a state in which pixel data that hasbeen output by the arrangement of FIG. 4A has been stored in a bandmemory;

FIG. 5A is a block diagram illustrating the configuration of an inputcorrection circuit according to the embodiment;

FIG. 5B is a block diagram illustrating the configuration of a pixelrearranging circuit according to the embodiment;

FIG. 6A is a flowchart illustrating an example of operation for pixelreadout according to the first embodiment;

FIG. 6B is a diagram useful in describing the pixel readout operation ofFIG. 6A;

FIG. 7A is a flowchart illustrating another example of operation forpixel readout according to the first embodiment;

FIG. 7B is a diagram useful in describing the pixel readout operation ofFIG. 7A;

FIG. 8A is a diagram useful in describing an array conversion operationin an array converter according to the first embodiment;

FIG. 8B is a diagram illustrating how the readout operation of FIG. 6Bis converted by the array conversion operation of FIG. 8A;

FIG. 8C is a diagram illustrating how the readout operation of FIG. 7Bis converted by the array conversion operation of FIG. 8A;

FIG. 9A is a diagram illustrating another example of the structure of aCCD sensor according to the first embodiment;

FIG. 9B is a diagram illustrating a state in which pixel data that hasbeen output by the arrangement of FIG. 9A has been stored in a bandmemory;

FIG. 9C is a diagram useful in describing another array conversionoperation in an array converter according to the first embodiment;

FIGS. 10A to 10E are diagrams illustrating arrays of image data in aband memory by various CCD sensor structures;

FIGS. 11A to 11J are diagrams illustrating operating modes of a bitarray control circuit according to the embodiment;

FIGS. 12A to 12D are diagrams useful in describing arrangement of pixeldata in a band memory in a case where a phase shift has occurred betweenshift registers, as well as sequence of readout from the band memory;and

FIG. 13 is a block diagram illustrating the configuration of a pixelrearranging circuit according to a second embodiment of the presentinvention.

DESCRIPTION OF THE EMBODIMENTS

Preferred embodiments of the present invention will now be describedwith reference to the accompanying drawings.

First Embodiment

Reference will be had to the block diagram of FIG. 1 to describe theconfigurations of an image reading unit, an image processing unit and animage output unit according to the first embodiment. The image readingunit, image processing unit and image output unit may be implemented asrespective separate units or as an apparatus in which any or all ofthese units are integrated. The image reading unit may be a scanner oras an image sensing unit such as a digital camera or digital videocamera. The image output unit may be a printing unit such as a printeror a display unit such as a display monitor. In a case where the imagereading unit, image processing unit and image output unit are eachconstructed as separate units, the units are connected via a local-areanetwork (LAN), etc., so as to be capable of communicating with oneanother.

As shown in FIG. 1, an image reading unit 120, an image processing unit130 and an image output unit (printer unit) 140 are integrated via a CPUcircuit 110.

In FIG. 1, the image reading unit 120 is composed of a CCD sensor 124and an analog signal processor 126, etc. An image of a document 100 thathas been formed on the CCD sensor 124 via a lens 122 is converted toanalog electric signals of the colors R (Red), G (Green) and B (Blue) bythe CCD sensor 124. The image information that has been converted tothese analog electric signals is input to the analog signal processor126 where it is subjected to an analog/digital (A/D) conversion after acorrection is applied to each of the colors R, G, B. The full-colorsignal (referred to as a “digital image signal” below) thus digitized isinput to the image processing unit 130.

The image processing unit 130 applies image processing to the digitalimage signal supplied from the image reading unit 120 (analog signalprocessor 126) and sends the processed digital image signal to theprinting unit 140. It should be noted that the processing implemented bythe image processing unit 130 is input correction processing, spatialfilter processing, color space conversion, density correction processingand halftone processing, described later. The printing unit 140 isconstituted by a printing output unit (not shown) that uses an ink-jethead or thermal head. The printing unit 140 forms a visible image onprinting paper in accordance with the digital image signal supplied fromthe image processing unit 130.

The CPU circuit 110 has a CPU 112 for controlling computations, a ROM114 storing fixed data and programs, and a RAM 116 used to store datatemporarily and to load programs. The CPU circuit 110 controls the imagereading unit 120, image processing unit 130 and printing unit 140, etc.,and exercises overall control of the operating sequence of theapparatus. An external storage unit 118 is a medium such as a disk forstoring parameters and programs used by the apparatus. Data and programsin the RAM 116 are loaded from the external storage unit 118.

The image processing unit 130 will now be described in detail. FIG. 2 isa block diagram illustrating an example of the configuration of an imageprocessing controller 200 possessed by the image processing unit 130according to the first embodiment. The digital image signal from theanalog signal processor 126 of the image reading unit 120 is input tothe image processing controller 200 via a bus 205. The image processingcontroller 200 comprises an input interface 210, an input correctioncircuit 220, a spatial filter circuit 230, a color space conversioncircuit 240, a density correction circuit 250, a halftone processingcircuit 260 and an output interface 270. The input correction circuit220, spatial filter circuit 230, color space conversion circuit 240,density correction circuit 250 and halftone processing circuit 260 willbe described in detail below.

[Input correction circuit 220] A digital image signal 215 is input tothe input correction circuit 220 via the input interface 210. Thedigital image signal 215 is composed of R, G, B luminance signals. Theinput correction circuit 220 executes pixel rearrangement processing(described later) for every color (R, G, B) of the digital image signal215 and executes processing that corrects for variation in the sensorthat reads the document and corrects the luminous intensity distributionof a document illuminating lamp.

[Spatial filter circuit 230] A digital image signal 225 (luminancesignals R1, G1, B1) that is output from the input correction circuit 220is input to the spatial filter circuit 230. The latter subjects theentered digital image signal 225 to local (nearby) image processing suchas smoothing and edge emphasis.

[Color space conversion circuit 240] A digital image signal 235(luminance signals R2, G2, B2) that is output from the spatial filtercircuit 230 is input to the color space conversion circuit 240. Thelatter converts the luminance signals (digital image signal 235) of RGBcolor space to density signals of CMYK color space.

[Density correction circuit 250] A digital image signal 245 (densitysignals C, M, Y, K) that is output from the color space conversioncircuit 240 is input to the density correction circuit 250. The lattersubjects the digital image signal 245 to an output-engine γ correction(density correction). In general, the input density of the halftoneprocessing circuit 260, which is the next stage, does not agree with theoutput density of the output engine of the printing unit 140 owing todot gain, etc. (the input and output are non-linear). Accordingly, inorder to so arrange it that a linear output conforming to input densityis obtained, the input/output density characteristic from the halftoneprocessing circuit 260 onward is corrected in advance by the γcorrection.

[Halftone processing circuit 260] A digital image signal 255 (densitysignals C1, M1, Y1, K1) that is output from the density correctioncircuit 250 is input to the halftone processing circuit 260. The lattersubjects the digital image signal 255 to halftone processing such asscreen processing and error-diffusion processing and converts the signalto binary halftone representation. A binary digital image signal 265(print signals C2, M2, Y2, K2) obtained by the halftone processingcircuit 260 is output to the printing unit 140 via the output interface270 and a bus 275.

Next, band processing used in the first embodiment will be described. Inband processing, one page of image data is divided into a plurality ofbands, the band areas are sequentially assigned to a band memory and aconversion is made to image data within the band areas.

In a low-cost device such as a household printer, there are many caseswhere the capacity of the line memory (which corresponds to the RAM 116in FIG. 1) of the system is so small that the entirety of the digitalimage data on one page cannot be stored in the line memory. For thisreason, the entirety of the digital image data on one page is dividedinto bands (rectangular strips), as illustrated in FIGS. 3A to 3D, onlythese areas are developed sequentially in the main memory and thenvarious image processing is executed. Each long and narrow area thusobtained by division is referred to as a “band area”, the storage areain which the band area is developed is referred to as a “band buffer” or“band memory”, and the act of dividing data into band areas is referredto as “band division”. The band memory stores several lines of pixeldata, which have been predetermined, from the image reading unit 120.The band memory is not necessarily reserved in the storage area of themain memory and may be reserved in any storage area in the system. Inthe first embodiment, it will be assumed that the band memory isreserved in the main memory in order to simplify the description.Further, separate from the coordinate system (main-scan direction vs.sub-scan direction) of the digital image data, a new coordinate system(band area coordinate system) of length direction vs. height direction,as shown in FIG. 3E, is defined, and the band area is expressed bylength (Bdl)×height (Bdh).

Band processing will now be described in somewhat more detail. First, aband area 301 shown in FIG. 3A is developed in the band memory of themain memory and image processing is executed. Next, a band area 302shown in FIG. 3B is developed by being written over the band memory inwhich the band area 301 was developed, and image processing is executed.Next, a band area 303 shown in FIG. 3C is developed by being writtenover the band memory in which the band area 302 was developed, and imageprocessing is executed. Finally, a band area 304 shown in FIG. 3D isdeveloped by being written over the band memory in which the band area303 was developed, and image processing is executed. It is evident fromFIGS. 3A to 3D that the band areas have identical lengths but need nothave identical heights. The band memory, which is the storage area inthe main memory, is decided by the band area of the largest size (bandareas 301 to 303 in the case of FIGS. 3A to 3D).

Further, the band memory in the main memory is not necessarily limitedto a single storage area, as described above. For example, it may be soarranged that a plurality of band memories are reserved in the mainmemory and image processing is executed in pipeline fashion. By way ofexample, two band areas A and B are provided, band area 301 is developedin band memory A and image processing (A) is executed. Next, the bandarea 301 is shifted from band memory A to band memory B and the bandarea 302 is developed in band memory A. Then, while image processing (B)is applied to the band area 301 in band memory B, image processing (A)is applied concurrently to the band area 302 in band memory B. Thus,pipeline image processing becomes possible by dividing digital imagedata into individual band areas and then executing image processing.

The image reading unit 120 of this embodiment will be described next.The image reading unit 120 has a line sensor (the CCD sensor 124 in thisembodiment) in which a plurality of image sensors (sensor elements) arearrayed in line form. The CCD sensor 124 produces an output in a form inwhich one line of image data has been divided into a plurality of lines.The direction in which the sensor elements are arrayed in the linesensor shall be referred to as the “line direction”.

For example, FIG. 4A is a diagram illustrating an example of thestructure of the CCD sensor 124 for one color among R, G, B. In FIG. 4A,reference characters 1 to n indicate individual sensor elements. Asensor block A and a sensor block B are usually physically disposedseveral lines apart. For example, the CCD sensor 124 has a configurationin which N (two in FIG. 4A) line sensors are arrayed in parallel in thesub-scan direction, which is perpendicular to the line direction. If welet d represent the distance between the centers of neighboring pixelswithin the line sensors, then the structure will be one in which N linesensors are disposed at a pitch of φ=d/N in the line direction. Itshould be noted that for the purpose of simplicity in the descriptionthat follows, the physical distance between sensor blocks A and B isassumed to be zero, i.e., it is assumed that all of the sensor elements1 to n have been arrayed on the same line. In accordance with such a CCDsensor, all of the pixel data 1 to n is acquired by a single scan in themain-scan direction.

In sensor blocks A and B, pixel data that has been read from each of thesensor elements of each block by scanning in the main-scan direction isstored in shift registers 401 to 404. The shift registers 401 and 403are connected to a sensor output unit 411, and the shift registers 402and 404 are connected to a sensor output unit 412. Pixel data is outputsuccessively from the sensor output units 411 and 412. At this time thesensor output unit 411 accepts alternatingly the output of the shiftregister 401 on the upper side of sensor block A and the output of theshift register 403 on the upper side of sensor block B and outputs thesignal as one line of data. Similarly, the sensor output unit 412accepts alternatingly the output of the shift register 402 on the lowerside of sensor block A and the output of the shift register 404 on thelower side of sensor block B and outputs the signal as one line of data.

The pixel data that has been output from the sensor output unit 411 andsensor output unit 412 is converted to a digital signal by the analogsignal processor 126, after which the digital signals are developed inthe band memory reserved in the RAM 116, etc. The outputs of the sensoroutput unit 411 and sensor output unit 412 are developed in the bandmemory as respective single lines of data. As illustrated in FIG. 4B,therefore, data that has been output from the sensor output unit 412 isdeveloped in the height direction of the band memory as the next line ofdata following the data from the sensor output unit 411.

In this embodiment, one scan of pixel data is divided into two lines andis developed in the band memory, as illustrated in FIG. 4B. This makesit necessary to rearrange pixels. That is, in a case where an attempt ismade to output single lines of pixel data in order, there is need for anarrangement in which pixels are extracted from the band memory, in whichthe pixel data has been stored, in the order 1, 2,3, . . . n, asillustrated in FIG. 4B. The rearranging of pixels according to thisembodiment will be described below. It this embodiment, the inputcorrection circuit 220 within the image processing unit 130 executesthis rearranging of pixels.

FIG. 5A is a block diagram illustrating the configuration of the inputcorrection circuit 220 according to this embodiment. As illustrated inFIG. 5A, the input correction circuit 220 has a pixel rearrangingcircuit 500 for rearranging pixels, and a sensor characteristiccorrection circuit 590. The entered pixel data is supplied to the sensorcharacteristic correction circuit 590 after rearrangement (describedlater) of the pixels by the pixel rearranging circuit 500. The sensorcharacteristic correction circuit 590 successively processes the pixeldata supplied from the pixel rearranging circuit 500 and outputs theprocessed data to the succeeding image processing.

FIG. 5B is a block diagram illustrating the details of the configurationof the pixel rearranging circuit 500. The rearrangement of pixels by thepixel rearranging circuit 500 will now be described in detail withreference to FIG. 5B.

As illustrated in FIG. 5B, the pixel rearranging circuit 500 has aheight-direction counter 510 (y_count), a length-direction counter 520(x_count) and a write-address counter 530 (w_count). Further, the pixelrearranging circuit 500 has a band memory 540 and a bit array controlcircuit 550 that includes an array converter 551.

Pixel data that has been input to the pixel rearranging circuit 500 isstored in the band memory in accordance with an address(write_addr[12:01]) that is output by the write-address counter 530, andthe pixel data is disposed as illustrated in FIG. 4B. When read data inan amount equivalent to the band height is stored in the band memory, areadout operation starts.

In the readout operation, a pixel position from which readout is to beperformed is designated by a height-direction pixel position signal(y_count[12:5]) from the height-direction counter 510 and alength-direction pixel position signal (x_count[6:0]) from thelength-direction counter 520. This pixel position indicates a pixelposition in a two-dimensional image. The sequence of designation ofpixel positions by the pixel position signals from the height-directioncounter 510 and length-direction counter 520 is one in which successivescanning of the band memory along the length direction is repeated alongthe height direction, as will be described later with reference to FIGS.6A and 6B. Alternatively, the sequence may be one in which successivescanning of the band memory along the height direction is repeated alongthe length direction, as will be described later with reference to FIGS.7A and 7B.

The pixel position signals from the height-direction counter 510 andlength-direction counter 520 are applied to the array converter 551,whereby the bit array is converted. This conversion processing generatesa band-memory readout address (read_addr[12:0]) suited to the state ofplacement of the pixel data shown in FIG. 4B, by way of example. Itshould be noted that the band memory may be a double buffer arrangement,in which case the writing of a second band can be executed while readoutof the first band is being performed. This makes it possible to raisethe speed of processing.

The operation of the height-direction counter 510 and length-directioncounter 520 will now be described with reference to FIGS. 6A, 6B andFIGS. 7A, 7B.

In a case where processing in the length direction of a band is executedfirst and then processing of the next line is executed sequentially inthe height direction of the band, pixel data at the upper left of theband (x_count=0, y_count=0) is read out first, as illustrated in FIG. 6A(steps S61, S62). Next, 1 is added to x_count and, if x_count has notreached the band length (Bdl−1), the next pixel is read out (steps S63,S64, S62). Thus, a pixel position signal for reading out pixelssuccessively in the length direction is generated.

If x_count has reached the band length (Bdl-1), x_count is cleared (stepS65). If y_count has not reached the band height (Bdh−1), then 1 isadded to y_count and data at the left end of the next line is read outin the height direction (steps S66, S67, S62). Thereafter, a similaroperation is repeated until x_count reaches the band length and y_countreaches the band height, whereby readout of one band is executed. If ithas been determined at step S66 that y_count has reached the bandheight, then y_count is cleared (step S68) and this processing isexited. As a result, a two-dimensional image is scanned in the mannerillustrated in FIG. 6B. In this embodiment, Bdl=n holds.

Described next will be a case where processing in the height directionof a band is executed first and then processing of the next pixel isexecuted sequentially in the length direction of the band. In this case,pixel data at the upper left of the band (x_count=0, y_count=0) is readout first, as illustrated in FIGS. 7A, 7B (steps S71, S72). Next, ify_count has not reached the band height (Bdh−1), then 1 is added toy_count and the next line is read out in the height direction (stepsS73, S74, S72). Thus, a pixel position signal for reading out pixelssuccessively in the height direction is generated.

If y_count has reached the band height (Bdh−1), y_count is cleared (stepS75). If x_count has not reached the band length (Bdl−1), then 1 isadded to x_count and data at the upper end of the next pixel is read outin the length direction (steps S76, S77, S72). Thereafter, a similaroperation is repeated until y_count reaches the band height and x_countreaches the band length, whereby readout of one band is executed. If ithas been determined at step S76 that x_count has reached the bandlength, then x_count is cleared (step S78) and this processing isexited. Thus, a two-dimensional image is scanned in the mannerillustrated in FIG. 7B.

In the case of the sensor structure of the first embodiment describedabove with reference to FIG. 4A, the image data is stored in the bandmemory 540 in the manner shown in FIG. 4B. Accordingly, the arrayconverter 551 performs an array conversion of y_count and x_count, asillustrated in FIG. 8A, and generates the readout address(read_addr[12:0]) of the band memory 540. At this time the sequence ofdata readout from the band memory 540 is as illustrated in FIG. 8B in acase where the length-direction counter 520 and height-direction counter510 are driven by the method illustrated in FIG. 6A. That is, thereadout sequence shown in FIG. 6B is changed to the sequence shown inFIG. 8B, and readout of pixel data from the band memory 540 is performedin accordance with this sequence.

Further, in a case where the length-direction counter 520 andheight-direction counter 510 are driven by the method shown in FIG. 7A,the sequence of data readout from the band memory 540 becomes as shownin FIG. 8C. That is, the readout sequence shown in FIG. 7B is changed tothe sequence shown in FIG. 8C, and readout of pixel data from the bandmemory 540 is performed in accordance with this sequence.

It should be noted that in a case where use is made of a sensor that hasnot been divided, 32 positions (0 to 4 bits) can be designated in thelength direction and 256 positions (5 to 12 bits) can be designated inthe height direction. On the other hand, in a case where there are twosensor outputs (division by 2), as in the present invention (FIG. 4A), aband that is twice as large in the length direction and half as large inthe height direction can be handled in comparison with a case where useis made of a same-size band memory and a sensor that has not beendivided. That is, FIG. 8A assumes a band memory having a band length of64 pixels and a band height of 128 lines. Depending upon the memorysize, however, other arrangements are possible.

Described above is a case where the CCD sensor 124 has a form(divided-by-two; two pixels) in which one line is divided into two linesand two consecutive pixels at a time are output successively from eachline, as illustrated in FIG. 4A. The present invention is not limited toan output form of this kind, as a matter of course. It should be notedthat the arrangement shown in FIG. 4A is suited to implementation ofhigher resolution with two identical sensors. In other words, resolutionis doubled by staggering sensor block A and sensor block B by one-halfpixel of the sensor pixel pitch. Since pixels for which the readoutclocks are in phase tend to be multiplexed, the wiring that results isthat of the sensor output units 411 and 412.

Another example of the structure of CCD sensor 124 will be describedbelow. FIG. 9A is a block diagram of the CCD sensor 124 in a case whereshift registers 901 to 904 of the sensor blocks have sensor outputs 911to 914. In the case of this sensor structure, image data that has beenread is developed in the band memory in the manner depicted in FIG. 9B.The form of output illustrated in FIGS. 9A, 9B is one (divided-by-four;one pixel) in which one line is divided into four lines and one pixel ata time is output successively from each line. In a case where pixel datahas been stored in the band memory 540 in the manner shown in FIG. 9B,it will suffice if the array conversion is performed in the arrayconverter 551 in the manner illustrated in FIG. 9C. In accordance withthis array converter 551, the readout sequence shown in FIG. 6B isconverted to the readout sequence that is in accordance with the orderof 1 to n in FIG. 9B, by way of example. Similarly, even in the readoutsequence shown in FIG. 7B, the pixel data is read out by the arrayconverter 551 band height at a time in an order that is in accordancewith the order of 1 to n.

Generalization of the method of generating access addresses by the arrayconverter 551 set forth above will now be described.

(1) First, the image reading unit 120 illustrated in FIGS. 4A, 4B and inFIGS. 9A, 9B is such that a plurality of sensor elements have linesensors (CCD sensors 124) arrayed in the line direction.

(2) The image reading unit 120 is such that one line of pixel signalsacquired by the line sensor is divided into m lines (where m is aninteger that is equal to or greater than 2) and signals are outputsuccessively in units of the divided lines. Here p continuous pixelsignals (where p is an integer that is equal to or greater than 1) thathave been extracted every other p×(m−1) pixels from one line of pixelsignals are disposed in each divided line. For example, FIGS. 4A, 4Billustrate a case where m=2, p=2 holds, and FIGS. 9A, 9B illustrate acase where m=4, p=1 holds. The form in which a line is divided into mlines and p consecutive pixels at a time are placed on each line will bereferred to as “divided-by-m; p pixels” below. For example, the form ofthe sensor output in FIG. 4A is “divided-by-two; two pixels”, and theform of the sensor output in FIG. 9A is “divided-by-four; one pixel”.

As illustrated in FIGS. 4B and 9B, pixel signals that have been outputfrom the image reading unit 120 are stored in the band memory 540 inthis output order by the write-address counter 530.

The length-direction counter 520 generates x_count as an X-positionsignal comprising a plurality of bits. This indicates position in the Xdirection, which corresponds to the line direction, of the imageobtained from the image reading unit 120. The height-direction counter510 generates y_count as a Y-position signal comprising a plurality ofbits. This indicates position in the Y direction, which is perpendicularto the X direction, of the image obtained from the image reading unit120. The bit array control circuit 550 rearranges the bit array of theX-position signal x_count and combines this with the Y-position signaly_count, thereby generating the access address signal (read_addr) foraccessing the band memory 540. In the input correction circuit 220,access to the band memory 540 is performed by the access address signalobtained by the above-mentioned address generation in the pixelrearranging circuit 500, a pixel signal is acquired and this is suppliedto the sensor characteristic correction circuit 590, whereby prescribedimage processing is applied.

The processing executed by the array converter 551 will now be describedin greater detail in accordance with the foregoing embodiment.

(1) The array converter 551 extracts the number of bits necessary toexpress the numerical value of p×m−1 from the side of the leastsignificant bit of the X-position signal x_count. For example, in bothFIGS. 4A and 9A, two bits (0^(th) bit and 1^(st) bit) necessary toexpress “3” are extracted.

(2) Remaining bits obtained by excluding the number of bits necessary toexpress the numerical value of p−1 from the extracted bits from thelower-order side thereof are connected to the least significant side ofthe Y-position signal y_count. In the case of the output format shown inFIG. 9A, “p−1=0” holds. Therefore, there are no excluded bits and theextracted two bits are connected as is to the least significant side ofthe Y-position signal y_count (see FIG. 9C). In the case of the outputformat shown in FIG. 4A, “p−1=1” holds. Therefore, one lower-order bit(the 0^(th) bit) is excluded and the remaining bit (the 1^(st) bit) isconnected to the least significant side of the Y-position signal y count(see FIG. 8A).

(3) The bit excluded in (2) above is connected to the least significantside of the X-position signal prevailing after bit extraction. Forexample, in the case of the output format of FIG. 4A, the 0^(th) bitexcluded in (2) above is connected to the least significant side of theX-position signal obtained following the extraction of the two bits in(1) above (see FIG. 8A).

The readout operations of FIGS. 6B and 7B are converted respectively asshown in FIGS. 8B and 8C by the array conversion operation of FIG. 8A.

(4) Furthermore, in the case of one pixel and two consecutive accessaddresses, as in a case where one pixel is 16 bits (two bytes), 0 isconnected to the least significant side of the access address generatedin (3) above and leading addresses of successive access are generated.Further, in the case of one pixel and four consecutive access addresses,0 is connected to the two bits on the least significant of the accessaddress generated in (3) above and leading addresses of successiveaccesses are generated. It should be noted that in order to thus obtainan arrangement in which the number of bits of one pixel is capable ofbeing selected in plural fashion, the unit of readout from the buffermemory is made to conform to a case where the number of bits of onepixel is maximized, and the necessary pixel data is selected by the bitson the least significant side. If this arrangement is adopted, thenumber of accesses will not change even if the number of bits of onepixel changes.

Accordingly, the sensor structure of the CCD sensor 124 to which thepresent invention is applicable is not limited to that described above.For example, if the shift registers 401, 402 are connected to the sensoroutput unit 411 and the shift registers 403, 404 are connected to thesensor output unit 412, then one pixel at a time is output sequentiallyfrom each line of the two lines. This form is referred to as“divided-by-two; one pixel”. In this case, pixel data is stored in theband memory 540 in an arrangement of the kind shown in FIG. 10B.

FIGS. 10C and 10D illustrate arrangement of pixel data in the bandmemory 540 in a case where use is made of the sensor structures of FIGS.4A and 9A, respectively. FIG. 10E illustrates arrangement of pixel datain the band memory 540 based upon the form “divided-by-four; two pixels”in which two pixels at a time area output successively from four lines(the sensor structure in this case is not illustrated). FIG. 10Aillustrates arrangement of pixel data in the band memory 540 in a caseline division is not performed.

FIGS. 11A to 11J illustrate examples of conversion of bit arrangementsby the array converter 551 corresponding to the sensor structuresmentioned above.

FIGS. 11A to 11E illustrate examples of conversion of bit arrangementscorresponding to the arrangements of pixel data illustrated in FIGS. 10Ato 10E, respectively. It should be noted that FIGS. 11A to 11E are for acase where the data size of one pixel is eight bits. On the other hand,the FIGS. 11F to 11J are for a case where the data size of one pixel is16 bits. In a case where the data size of one pixel is 16 bits, aportion equivalent to two addresses of the buffer memory is occupied byone pixel. Accordingly, readout is always performed in units of twoaddresses and 0 is always assigned to the least significant bit(read_addr[0]) of the address. That is, the array converter 551, afterperforming an array conversion in the manner shown in FIGS. 11B to 11E,inserts 0 as the least significant bit and shifts bits 0 to 3 to bits 1to 4.

In accordance with a command from the CPU 112, the array converter 551of this embodiment is capable of selectively executing an arrayconversion of the kind shown in FIGS. 11A to 11J above. That is, using aparameter that has been stored in the external storage unit 118, etc.,the CPU 112 instructs the bit array control circuit 550 of the operatingmode of the array converter 551 and can change over the type of arrayconversion. Accordingly, pixel rearrangements corresponding to varioustypes of sensor structures can be implemented in one and the same imageprocessing system.

In accordance with the first embodiment, as described above, pixel datais stored sequentially in a pixel-data memory (band memory) in the formof the array that entered from the CCD sensor 124. A first counter thatindicates pixel position (x_count) in the length direction (main-scandirection) and a second counter that indicates pixel position (y_count)in the height direction (sub-scan direction) designate a pixel positionthat prevails following reconstruction of the image to be read out. Thebit array control circuit 550 makes a conversion to a readout address ofthe band memory 540 corresponding to the pixel position designated byx_count and y_count. By performing readout from the band memory 540according to this readout address, the image data is rearranged anddesired image data can be obtained. Further, it is possible to deal witha plurality of dividing modes of a scanner in simple fashion.

Second Embodiment

A second embodiment will now be described. There are cases where,depending upon the circumstances of assembly of the CCD sensor 124 orimage reading range, the ends of the sensor cannot be used and readoutis performed from a pixel position that is not at the boundary of sensordivision. For example, in the sensor structure shown in FIG. 4A, thereare cases where the first sensor element of sensor block A cannot beused and pixel data is output from the shift register 401 with thefourth pixel serving as the beginning. In such cases a phase shiftdevelops in the output from shift register A and pixel data is stored inthe band memory 540 in the arrangement shown in FIG. 12B. Further, in acase where there is a shift of one pixel in the “divided-by-two; onepixel” arrangement, the pixel data is arranged as shown in FIG. 12A.Similarly, in a case where there is a shift of two pixels in the“divided-by-four; one pixel” arrangement, the pixel data is arranged asshown in FIG. 12C, and in a case where there is a shift of four pixelsin the “divided-by-four; two pixels” arrangement, the pixel data isarranged as shown in FIG. 12D. In this case, it is necessary to read outthe images in the order of the numerals shown in FIGS. 12A to 12D. Withthe pixel rearranging circuit 500 described in the second embodiment,even if there is a shift in phase, the phase shift can be compensatedfor and image data can be rearranged correctly without arranging pixels,which have been developed in the band memory 540, in the mannerillustrated in the first embodiment. It should be noted that the phasecompensation in the second embodiment is for dealing with a case wherepixels have been shifted in units of p pixels in a sensor of the“divided-by-m; p pixels” arrangement.

FIG. 13 is a block diagram illustrating the configuration of the pixelrearranging circuit 500 according to a second embodiment.

As shown in FIG. 13, the three lower-order bits (x_count[2:0]) of theoutput of length-direction counter 520 are connected to aphase-compensating adder 552 in the bit array control circuit 550 of thefirst embodiment. The output (p_count[2:0]) of the phase-compensatingadder 552 is connected to the array converter 551. Thephase-compensating adder 552 is a circuit for adding on a designatedoffset value in accordance with the operating mode of the arrayconverter 551. The range of bits added on by the phase-compensatingadder 552 is decided by the operating mode, and the offset value isdesignated by a parameter stored in the external storage unit 118, etc.The CPU 112 instructs the bit array control circuit 550 of these items.

As illustrated in FIGS. 11A to 11J, the pixel rearranging circuit 500moves some of the bits of the bit array of the output (X-positionsignal) from length-direction counter 520 to the higher-order side andcouples the height-direction counter 510 (Y-position signal) to thehigher-order side of the X-position signal. An access address signalsuited to the band memory is generated by this operation. In order toread out pixels in the order illustrated in FIGS. 12A to 12D owing tooccurrence of the pixel shift mentioned above, the phase-compensatingadder 552 performs addition with the target being the output bits of thelength-direction counter 520 moved to the most significant side of the Xposition (the side of the Y-position signal). More specifically,addition is performed as follows:

-   in case of “divided-by-two; one pixel”, 1 is added to x_count[0:0]    moved to the side of the Y-position signal (the most significant    side);-   in case of “divided-by-two; two pixels”, 1 is added to x_count[1:1]    moved to the side of the Y-position signal (the most significant    side);-   in case of “divided-by-four; one pixel”, any one of 1 to 3 is added    to x_count[1:0] moved to the side of the Y-position signal (the most    significant side) (2 is added in FIG. 12C); and-   in case of “divided-by-four; two pixels”, any one of 1 to 3 is added    to x_count[2:1] moved to the side of the Y-position signal (the most    significant side) (2 is added in the above-described figure).

Accordingly, if the operating mode is that of FIG. 11B or 11G, thearrangement is the “divided-by-two; one pixel” arrangement and thereforethe phase-compensating adder 552 performs offset addition with regard toone bit of the least significant one bit x count[0:0]. In the case ofFIGS. 11C and 11H, the arrangement is the “divided-by-two; two pixels”arrangement and therefore the phase-compensating adder 552 performsoffset addition with regard to one bit of x count[1:1]. In the case ofFIGS. 11D and 11I, the arrangement is the “divided-by-four; one pixel”arrangement and therefore the phase-compensating adder 552 performsoffset addition with regard to two bits of x count[1:0]. In the case ofFIGS. 11E and 11J, the arrangement is the “divided-by-four; two pixels”arrangement and therefore the phase-compensating adder 552 performsoffset addition with regard to two bits of x_count[2:1]. It should benoted that a carry produced by addition is ignored in thephase-compensating adder 552.

As mentioned above, the bit array control circuit of the secondembodiment has the phase-compensating adder 552 for performing phasecompensation before the bit array is rearranged by the array converter551. The phase-compensating adder 552 performs phase-compensatingaddition with respect to bits that are the target for movement to themost significant side (the side of connection to the Y-position signal)in the bit array of the X-position signal (x_count). The value added isan integral value selected from among numerical values within a rangecapable of being expressed by the number of bits that are the target ofmovement. For example, in the case where the form of the sensor outputis “divided-by-four; two pixels”, phase is compensated for by adding anyintegral value of 0 to 3 capable of being expressed by two bits to therange of two bits of x_count[2:1] that is the target of movement.

In accordance with the second embodiment described above, an address forreading pixel data, which corresponds to any pixel position in a bandarea, from the band memory 540 is generated by the bit array controlcircuit 550. Accordingly, the order of pixel positions designated by theheight-direction counter 510 and length-direction counter 520 is notlimited to that described above; pixel positions can be designated inany order.

Further, it may be so arranged that the operation of the array converter551 or phase-compensating adder 552 can be set by a jumper or by acommand from the CPU 112 so as to make it possible to deal with dividedreadout of a plurality of types or with a phase shift. If such anarrangement is adopted, a common pixel rearranging circuit 500 can beutilized in image reading units 120 having different forms of dividedreadout or different phase differences.

Thus, in accordance with the foregoing embodiments, even if output froma sensor is stored in a band memory in a form divided according to thearray of sensor elements, a correct pixel signal can be obtained fromthe band memory in accordance with readout by an image processing unitat the time of readout in the sub-scan direction in band units.

While the present invention has been described with reference toexemplary embodiments, it is to be understood that the invention is notlimited to the disclosed exemplary embodiments. The scope of thefollowing claims is to be accorded the broadest interpretation so as toencompass all such modifications and equivalent structures andfunctions.

This application claims the benefit of Japanese Patent Application No.2007-117561, filed Apr. 26, 2007, which is hereby incorporated byreference herein in its entirety.

1. An image data combining apparatus for combining m lines (where m isan integer equal to or greater than 2) of image data that have beenoutput from a reading unit, wherein the reading unit has a plurality ofline sensors arranged in parallel, each of the plurality of line sensorsoutputs pixel data upon dividing the data into a plurality of lines, thereading unit outputs m lines of image data based upon the pixel datathat has been output upon being divided into the plurality of lines, andthe output m lines of image data are stored in a memory, said apparatuscomprising: an access unit configured to access the memory; and adetermination unit configured to determine an upper address used foraccessing the memory by said access unit, based upon first data thatindicates position, along the sub-scan direction, of an image that hasbeen read by the reading unit, and determine a lower address used foraccessing the memory by said access unit, based upon second data thatindicates position of the image along the main-scan direction; whereinthe lower address includes values in which the sequence of a pluralityof bits constituting the second data is interchanged in such a mannerthat p items (where p is an integer equal to or greater than 1) of pixeldata at a time are extracted successively from each of the m lines ofimage data.
 2. The apparatus according to claim 1, wherein the loweraddress includes values in which one or more first bits and one or moresecond bits of the second data are interchanged; the one or more firstbits is a bit or bits obtained by removing the number of bits necessaryto represent the numerical value p−1 from the bits which are obtained byextracting the number of bits necessary to represent a numerical valuep×m−1 from the least significant side of the second data; and the one ormore second bits is a bit or bits obtained by removing, from the seconddata, the number of bits necessary to represent the numerical valuep×m−1 from the least significant side of the second data.
 3. Theapparatus according to claim 1, wherein if there are two successiveaccesses, then one bit of value 0 is connected to the lower address onthe lower-order side of the plurality of bits constituting the seconddata, and if there are four successive accesses, then two bits of value0 are connected to the lower address on the lower-order side of theplurality of bits constituting the second data.
 4. The apparatusaccording to claim 1, wherein with respect to some bits whose sequenceis interchanged among the plurality of bits constituting the seconddata, an integral value selected from among numerical values within arange capable of being represented by the number of bits of said somebits is added to the lower address.
 5. The apparatus according to claim1, wherein the reading unit has N line sensors arranged in parallel;said N line sensors being disposed at a pitch of φ=d/N in the main-scandirection, where d represents the distance between the centers ofneighboring pixels within the line sensors.
 6. The apparatus accordingto claim 1, wherein the memory is a band memory for storing apredetermined several lines of image data.
 7. An image data combiningmethod for combining m lines (where m is an integer equal to or greaterthan 2) of image data that have been output from a reading unit, whereinthe reading unit has a plurality of line sensors arranged in parallel,each of the plurality of line sensors outputs pixel data upon dividingthe data into a plurality of lines, the reading unit outputs m lines ofimage data based upon the pixel data that has been output upon beingdivided into the plurality of lines, and the output m lines of imagedata are stored in a memory, said method comprising: an access step ofaccessing the memory; and a determination step of determining an upperaddress used for accessing the memory at said access step, based uponfirst data that indicates position, along the sub-scan direction, of animage that has been read by the reading unit, and determining a loweraddress used for accessing the memory at said access step, based uponsecond data that indicates position of the image along the main-scandirection; wherein the lower address includes values in which thesequence of the plurality of bits constituting the second data isinterchanged in such a manner that p items (where p is an integer equalto or greater than 1) of pixel data at a time are extracted successivelyfrom each of the m lines of image data.
 8. The method according to claim7, wherein the lower address includes values in which one or more firstbits and one or more second bits of the second data are interchanged;the one or more first bits is a bit or bits obtained by removing thenumber of bits necessary to represent the numerical value p−1 from thebits which are obtained by extracting the number of bits necessary torepresent a numerical value p×m−1 from the least significant side of thesecond data; and the one or more second bits is a bit or bits obtainedby removing, from the second data, the number of bits necessary torepresent the numerical value p×m−1 from the least significant side ofthe second data.
 9. The method according to claim 7, wherein if thereare two successive accesses, then one bit of value 0 is connected to thelower address on the lower-order side of the plurality of bitsconstituting the second data, and if there are four successive accesses,then two bits of value 0 are connected to the lower address on thelower-order side of the plurality of bits constituting the second data.10. The method according to claim 7, wherein with respect to some bitswhose sequence is interchanged among the plurality of bits constitutingthe second data, an integral value selected from among numerical valueswithin a range capable of being represented by the number of bits ofsaid some bits is added to the lower address.